package banking;

import java.util.ArrayList;
import java.util.List;

public class Bank {
    private final List<Customer> customersList = new ArrayList<>();

    private static final Bank bank = new Bank();

    private Bank(){}

    public void addCustomer(String firstName, String lastName) {
        addCustomer(new Customer(firstName, lastName));
    }

    public void addCustomer(Customer customer){
        customersList.add(customer);
    }

    public int getNumOfCustomers() {
        return customersList.size();
    }

    public Customer getCustomer(int index){
        return customersList.get(index);
    }

    public static Bank getBank(){
        return bank;
    }

}
